import {createRouter, createWebHistory} from "vue-router";
import HomeView from "@views/HomeView.vue";
import NotFoundView from "/@/components/NotFoundView.vue";

const router = createRouter({
    history: createWebHistory(import.meta.env.BASE_URL),
    routes: [
        {
            path: "/",
            redirect: "/home"
        },
        {
            path: "/home",
            name: "home",
            component: HomeView,
        },
        {
            path: "/404",
            name: "404",
            component: NotFoundView,
        },
        {
            path: "/:catchAll(.*)",
            redirect: "/404",
        },
    ]
});

export default router;